package cn.tedu.es.repository;

import cn.tedu.es.entity.Student;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;


import java.util.List;

/**
 * @description:
 * @author: LiuXingYu
 * @date: 2021/9/29 10:41
 */
public interface StudentRepository extends ElasticsearchRepository<Student, Long> {

    Page<Student> findByName(String name, Pageable pageable);

    List<Student> findByNameOrBirthDate(String name, String birthDate);

}